<%-- 
    Document   : news
    Created on : 19 janv. 2013, 12:41:42
    Author     : gabriellebotbol
--%>

<%@page import="models.Messenger"%>
<%@page import="java.util.ArrayList"%>
<%@page import="buisness.Messages"%>
<%@page import="javax.security.auth.message.callback.PasswordValidationCallback"%>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@page errorPage="error.jsp" %>
<!DOCTYPE html>
<html>
    <%@include file="WEB-INF/jspf/head.jspf"%>
    <body>
        <%@include file="WEB-INF/jspf/header.jspf"%>
        <div class="page">
            <div class="content">
                <p>
                <a href="./messages">Wall</a>
                <a href="./friends">Friends</a>
                <a href="./logout">Logout</a></p>
                <% 
                    request.getSession(true).setAttribute("type", "wall");
                    ArrayList<Messenger> allMessenger=new ArrayList();
                    allMessenger = (ArrayList) request.getSession().getAttribute("Messengers");
                    for (Messenger mail : allMessenger)
                    {
                        %><p><%out.println(mail.getBody());%></p><%
                    }

                %>
            </div>
        </div>
        <%@include file="WEB-INF/jspf/footer.jspf"%>      
    </body>
    
</html>
